Repository navigation
Benchmark the Doors checks on one content page - #1287
LukasWallrich wants to merge 14 commits into
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
👍 All image files/references (if any) are in webp format, in line with our policy. |
✅ Spell Check PassedNo spelling issues found when checking 8 changed file(s)! 🎉 |
There was a problem hiding this comment.
6 issues found across 7 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name=".github/workflows/rebrand-preview.yaml">
<violation number="1" location=".github/workflows/rebrand-preview.yaml:140">
P2: The preview now builds immediately after applying the production artifact, so it no longer regenerates `content/contributors/tenzing.md` with the redesign branch’s generator. Restore that generation step before Hugo; otherwise the preview uses the production Contributors markup and can render stale structure and counts.</violation>
<violation number="2" location=".github/workflows/rebrand-preview.yaml:205">
P2: This benchmark override is unconditional: every eligible unlabeled PR writes `scoped=true`, so changes to this workflow, check scripts, or `sample_pages.json` can avoid the required full browser suite. Limit the override to the benchmark run or restore the diff-based full-suite guard before merging.
(Based on your team's feedback about sample-page scope handling.) .</violation>
<violation number="3" location=".github/workflows/rebrand-preview.yaml:484">
P2: This removes the baseline comparison from the internal-link check, so pre-existing broken links now fail as new links, especially on PRs into `rebrand-doors` where `main-reference` is skipped. Make the site-check job download and pass the appropriate base/reference build, or keep this check in the job that already has that reference.</violation>
</file>
<file name="scripts/rebrand/changed_pages.py">
<violation number="1" location="scripts/rebrand/changed_pages.py:15">
P2: `normalize` drops SRI from every `<link>`/`<script>`, including unfingerprinted vendor resources. An `sri`-only change in `data/assets.toml` therefore selects no checks, even though it can change whether that dependency loads.</violation>
</file>
<file name="scripts/rebrand/check_axe.py">
<violation number="1" location="scripts/rebrand/check_axe.py:67">
P2: The scoped selection reintroduces `/404.html` even though full runs explicitly exclude it. A diff touching the error page will now run axe against it and can fail on unrelated 404-only markup; remove `/404.html` from `pages` before either scoped branch selects URLs.</violation>
</file>
<file name="scripts/rebrand/check_design.py">
<violation number="1" location="scripts/rebrand/check_design.py:1695">
P2: Core mode now drops three quarters of the existing article coverage whenever bundles change. Preserve the established sample and union the changed article paths: `paths = sorted(set(paths) | set(article_paths(public, pages)))`.</violation>
</file>
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
| run: | | ||
| python3 scripts/rebrand/check_internal_links.py public --base "$PREVIEW_BASE" \ | ||
| --reference "$RUNNER_TEMP/public-reference" | ||
| run: python3 scripts/rebrand/check_internal_links.py public --base "$PREVIEW_BASE" |
There was a problem hiding this comment.
P2: This removes the baseline comparison from the internal-link check, so pre-existing broken links now fail as new links, especially on PRs into rebrand-doors where main-reference is skipped. Make the site-check job download and pass the appropriate base/reference build, or keep this check in the job that already has that reference.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At .github/workflows/rebrand-preview.yaml, line 484:
<comment>This removes the baseline comparison from the internal-link check, so pre-existing broken links now fail as new links, especially on PRs into `rebrand-doors` where `main-reference` is skipped. Make the site-check job download and pass the appropriate base/reference build, or keep this check in the job that already has that reference.</comment>
<file context>
@@ -211,22 +439,49 @@ jobs:
- run: |
- python3 scripts/rebrand/check_internal_links.py public --base "$PREVIEW_BASE" \
- --reference "$RUNNER_TEMP/public-reference"
+ run: python3 scripts/rebrand/check_internal_links.py public --base "$PREVIEW_BASE"
- name: Built HTML (headings, conditional assets, image alt and dimensions)
</file context>
| run: | | ||
| git fetch --no-tags --filter=blob:none origin "$HEAD_SHA" | ||
| # Benchmark the post-merge single-page path with PR #1278 still open. | ||
| echo "scoped=true" >> "$GITHUB_OUTPUT" |
There was a problem hiding this comment.
P2: This benchmark override is unconditional: every eligible unlabeled PR writes scoped=true, so changes to this workflow, check scripts, or sample_pages.json can avoid the required full browser suite. Limit the override to the benchmark run or restore the diff-based full-suite guard before merging.
(Based on your team's feedback about sample-page scope handling.) .
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At .github/workflows/rebrand-preview.yaml, line 205:
<comment>This benchmark override is unconditional: every eligible unlabeled PR writes `scoped=true`, so changes to this workflow, check scripts, or `sample_pages.json` can avoid the required full browser suite. Limit the override to the benchmark run or restore the diff-based full-suite guard before merging.
(Based on your team's feedback about sample-page scope handling.) .</comment>
<file context>
@@ -36,132 +39,299 @@ concurrency:
+ run: |
+ git fetch --no-tags --filter=blob:none origin "$HEAD_SHA"
+ # Benchmark the post-merge single-page path with PR #1278 still open.
+ echo "scoped=true" >> "$GITHUB_OUTPUT"
+
+ - name: Reuse a matching push build
</file context>
|
|
||
|
|
||
| def normalize(html): | ||
| def clean_tag(match): |
There was a problem hiding this comment.
P2: normalize drops SRI from every <link>/<script>, including unfingerprinted vendor resources. An sri-only change in data/assets.toml therefore selects no checks, even though it can change whether that dependency loads.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At scripts/rebrand/changed_pages.py, line 15:
<comment>`normalize` drops SRI from every `<link>`/`<script>`, including unfingerprinted vendor resources. An `sri`-only change in `data/assets.toml` therefore selects no checks, even though it can change whether that dependency loads.</comment>
<file context>
@@ -0,0 +1,92 @@
+
+
+def normalize(html):
+ def clean_tag(match):
+ return INTEGRITY.sub("", match[0])
+
</file context>
| parser.add_argument("--axe", required=True, help="path to axe.min.js") | ||
| parser.add_argument("--out", help="write every finding to this JSON file") | ||
| args = parser.parse_args() | ||
| mode, pages = load_selection(args.pages) |
There was a problem hiding this comment.
P2: The scoped selection reintroduces /404.html even though full runs explicitly exclude it. A diff touching the error page will now run axe against it and can fail on unrelated 404-only markup; remove /404.html from pages before either scoped branch selects URLs.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At scripts/rebrand/check_axe.py, line 67:
<comment>The scoped selection reintroduces `/404.html` even though full runs explicitly exclude it. A diff touching the error page will now run axe against it and can fail on unrelated 404-only markup; remove `/404.html` from `pages` before either scoped branch selects URLs.</comment>
<file context>
@@ -57,14 +59,26 @@ def main():
parser.add_argument("--axe", required=True, help="path to axe.min.js")
parser.add_argument("--out", help="write every finding to this JSON file")
args = parser.parse_args()
+ mode, pages = load_selection(args.pages)
+ if mode == "none":
+ if args.out:
</file context>
| mode, pages = load_selection(args.pages) | |
| mode, pages = load_selection(args.pages) | |
| pages.discard("/404.html") |
| paths = article_paths(public) | ||
| paths = article_paths(public, selected) | ||
| if mode == "core": | ||
| paths = sorted(set(paths[::4]) | set(article_paths(public, pages))) |
There was a problem hiding this comment.
P2: Core mode now drops three quarters of the existing article coverage whenever bundles change. Preserve the established sample and union the changed article paths: paths = sorted(set(paths) | set(article_paths(public, pages))).
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At scripts/rebrand/check_design.py, line 1695:
<comment>Core mode now drops three quarters of the existing article coverage whenever bundles change. Preserve the established sample and union the changed article paths: `paths = sorted(set(paths) | set(article_paths(public, pages)))`.</comment>
<file context>
@@ -1622,10 +1680,19 @@ def main():
- paths = article_paths(public)
+ paths = article_paths(public, selected)
+ if mode == "core":
+ paths = sorted(set(paths[::4]) | set(article_paths(public, pages)))
print(f"Every article page: {len(paths)} pages", flush=True)
shards = max(1, 2 * args.jobs)
</file context>
| paths = sorted(set(paths[::4]) | set(article_paths(public, pages))) | |
| paths = sorted(set(paths) | set(article_paths(public, pages))) |
|
|
||
| # HUGO_ENV=staging adds noindex and leaves out Google Analytics. | ||
| - name: Build the branch | ||
| run: hugo --cacheDir "$RUNNER_TEMP/hugo-cache" --minify --cleanDestinationDir --destination public --baseURL "$PREVIEW_URL" |
There was a problem hiding this comment.
P2: The preview now builds immediately after applying the production artifact, so it no longer regenerates content/contributors/tenzing.md with the redesign branch’s generator. Restore that generation step before Hugo; otherwise the preview uses the production Contributors markup and can render stale structure and counts.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At .github/workflows/rebrand-preview.yaml, line 140:
<comment>The preview now builds immediately after applying the production artifact, so it no longer regenerates `content/contributors/tenzing.md` with the redesign branch’s generator. Restore that generation step before Hugo; otherwise the preview uses the production Contributors markup and can render stale structure and counts.</comment>
<file context>
@@ -36,132 +39,299 @@ concurrency:
+
+ # HUGO_ENV=staging adds noindex and leaves out Google Analytics.
+ - name: Build the branch
+ run: hugo --cacheDir "$RUNNER_TEMP/hugo-cache" --minify --cleanDestinationDir --destination public --baseURL "$PREVIEW_URL"
+ env:
+ HUGO_ENV: staging
</file context>
Measures the scoped Syllabus edit. The draft includes #1278 and bypasses the workflow-change scope guard to simulate a single-page PR after #1278 lands.
Created with GPT-6.2 Sol in Codex.
🤖 Generated with Claude Code
Summary by cubic
Benchmarks the scoped browser checks with a one-line Syllabus title edit, measuring what a single-page PR costs once #1278 lands. The PR bypasses the workflow-change scope guard to simulate the post-merge path.
rebrand-doorsnow build their PR base (reusing a matching push build when its commit and input artifacts match) and run browser checks only on the pages that differ from it.changed_pages.pyto compare the built sites and select a check mode: full, core, changed pages only, or none.full-checkslabel run the full suite.mainstill run the full comparison against the main merge base; PRs skip it, and their internal-link check keeps its five known exceptions in the allowlist.Written for commit 583bbcd. Summary will update on new commits.